+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
+Wed Jan 9 19:10:07 2002 Jonathan Blandford <jrb@redhat.com>
+
+ * gtk/gtktreeselection.c
+ (_gtk_tree_selection_internal_select_node): Now we test we can
+ unselect nodes before selecting new ones.
+ (gtk_tree_selection_real_select_node): be careful comparing booleans.
+
Wed Jan 9 21:31:44 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtkliststore.c (gtk_list_store_sort): pass NULL to
</para>
+
<!-- ##### FUNCTION gdk_threads_leave ##### -->
<para>
Leaves a critical region begun with gdk_threads_enter().
</para>
+
+
<!-- ##### VARIABLE gdk_threads_mutex ##### -->
<para>
The #GMutex used to implement the critical region for
GtkTreeViewColumn *drag_column;
/* bin_window offset */
+ GtkTreeRowReference *top_row;
+ gint top_row_dy;
gint dy;
gint drag_column_x;
}
else
{
- /* FIXME: We only want to select the new node if we can unselect the
- * old one, and we can select the new one. We are currently
- * unselecting the old one first, then trying the new one. */
if (anchor_path)
{
- dirty = gtk_tree_selection_real_unselect_all (selection);
+ /* We only want to select the new node if we can unselect the old one,
+ * and we can select the new one. */
+ if (selection->user_func)
+ {
+ if ((*selection->user_func) (selection, selection->tree_view->priv->model, path,
+ GTK_RBNODE_FLAG_SET (node, GTK_RBNODE_IS_SELECTED),
+ selection->user_data))
+ dirty = TRUE;
+ }
+ else
+ {
+ dirty = TRUE;
+ }
+
+ /* if dirty is FALSE, we weren't able to select the new one, otherwise, we try to
+ * unselect the new one
+ */
+ if (dirty)
+ dirty = gtk_tree_selection_real_unselect_all (selection);
+
+ /* if dirty is TRUE at this point, we successfully unselected the
+ * old one, and can then select the new one */
if (dirty)
{
if (selection->tree_view->priv->anchor)
gboolean selected = FALSE;
GtkTreePath *path = NULL;
+ select = !! select;
+
if (GTK_RBNODE_FLAG_SET (node, GTK_RBNODE_IS_SELECTED) != select)
{
path = _gtk_tree_view_find_path (selection->tree_view, tree, node);